<style>
	.layui-form-item{margin-bottom: 0;}
	.product-info .img-block{width:60px;height:60px;float:left;border:1px solid #e2e2e2;display: flex;align-items: center;justify-content: center;}
	.product-info .img-block>img{max-width:100%;max-height:100%;}
	.product-info .info{margin-left:70px}
	.product-info .info p{color:#8e8c8c;font-size:12px}
	.commission-info dl{display: flex;align-items: center;margin-bottom: 10px}
	.commission-info dl:last-child{margin-bottom: 0;}
    .commission-info dl dd{flex: 1;padding-left: 10px;}
    .address{height: 0;width: 1px; border: none; overflow: hidden;}
</style>

<div class="order-detail">
    <div class="layui-row layui-col-space1 order-detail-info" >
        <div class="order-detail-left" >
            <div class="layui-card card-common card-brief">
                <div class="layui-card-header nav-title">
                    <span class="card-title">订单信息</span>
                </div>
                <div class="layui-card-body">
                    <div class="layui-form">
                        <div class="layui-form-item">
                            <label class="layui-form-label">订单编号：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">{$order_detail['order_no']}</div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">订单类型：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">{$order_detail['order_type_name']}</div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">订单来源：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">
                                        <p>{$order_detail.order_from_name}</p>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">付款方式：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">{$order_detail.pay_type_name}</div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">买家：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">{$order_detail.nickname}</div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item order-detail-hr"></div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">配送方式：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">
                                        <p>{$order_detail['delivery_type_name']}</p>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">收货人：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">
                                        <p>{$order_detail['name']}</p>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">联系电话：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">
                                        <p>{$order_detail['mobile']}</p>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">收货地址：</label>
                            <div class="layui-input-block">
                                <div class="layui-inline">
                                    <div class="layui-form-mid layui-word-aux">
                                        <p>{$order_detail['full_address']}-{$order_detail['address']}
                                            <input type="text" class="address" id="address" value="{$order_detail['full_address']}-{$order_detail['address']}">
                                            <a href="javascript:ns.copy('address');" class="iconfont iconfuzhi" style="margin-top: 4px"></a>
                                        </p>
                                    </div>
                                </div>
                            </div>
                        </div>
                        
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<div style="height: 15px;"></div>

{notempty name="$order_detail['order_goods']"}
<div class="order-detail-table">
    <table class="layui-table" lay-filter="parse-table-order-product" lay-skin="line" lay-size="lg">
        <thead>
        	<colgroup>
        		<col width="35%">
        		<col width="20%">
        		<col width="30%">
        		<col width="15%">
        	</colgroup>
	        <tr>
	            <th>商品信息</th>
	            <th style="text-align:right">单价(元) / 数量</th>
	            <th>分佣信息</th>
	            <th>佣金状态</th>
	        </tr>
        </thead>
        <tbody>
	        {foreach $order_detail['order_goods'] as $list_k => $order_goods_item}
	        <tr>
	            <td>
	            	<div class="product-info">
		            	<div class="img-block">';
							<img layer-src src="{:img($order_goods_item.sku_image, 'small')}">
						</div>
						<div class="info">
							<span title="{$order_goods_item.sku_name}" class="multi-line-hiding text-color">{$order_goods_item.sku_name}</span>
						</div>
					</div>
				</td>
	            <td style="text-align:right;">
	            	<div>{$order_goods_item.price}</div>
	            	<div>{$order_goods_item.num}件</div>
            	</td>
	            <td class="commission-info">
	            	<dl>
	            		<dt>一级分佣</dt>
	            		<dd>
	            			{if $order_goods_item.one_commission > 0}
			            		<div class="title-left">分销商：{$order_goods_item.one_fenxiao_name}</div>
			            		<div class="title-left">佣金：¥{$order_goods_item.one_commission}</div>
		            		{else/}
	            				<div class="title-left">分销商：--</div>
		            			<div class="title-left">佣金：--</div>
		            			<div class="title-left">分佣比率：--</div>
		            		{/if}
	            		</dd>
	            	</dl>
	            	<dl>
	            		<dt>二级分佣</dt>
	            		<dd>
	            			{if $order_goods_item.two_commission > 0}
			            		<div class="title-left">分销商：{$order_goods_item.two_fenxiao_name}</div>
			            		<div class="title-left">佣金：¥{$order_goods_item.two_commission}</div>
		            		{else/}
	            				<div class="title-left">分销商：--</div>
		            			<div class="title-left">佣金：--</div>
		            		{/if}
	            		</dd>
	            	</dl>
	            	<dl>
	            		<dt>三级分佣</dt>
	            		<dd>
	            			{if $order_goods_item.three_commission > 0}
			            		<div class="title-left">分销商：{$order_goods_item.three_fenxiao_name}</div>
			            		<div class="title-left">佣金：¥{$order_goods_item.three_commission}</div>
		            		{else/}
	            				<div class="title-left">分销商：--</div>
		            			<div class="title-left">佣金：--</div>
		            		{/if}
	            		</dd>
	            	</dl>
	            </td>
	            <td colspan="{:count($order_detail['order_goods'])}">
                    {if $order_detail.order_status == -1}
                        {$order_detail.order_status_name}
                    {else/}
                        {$order_detail['order_goods'][0]['is_settlement'] == 1 ? '已结算': '待结算'}
                    {/if}
	            </td>
	        </tr>
	        {/foreach}
        </tbody>
    </table>
</div>
{/notempty}